package hmvc4gwt.client.model;

import hmvc4gwt.client.controller.IController;

public abstract class AbstractModel implements IModel {
	
	private IController controller;

	private boolean terminated = false;
	
	private boolean initialized = false;	
	
	public IController getController() {
		return controller;
	}

	public void setController(IController controller) {
		this.controller = controller;
	}

	public void setInitialized(boolean b) {
		initialized = b;
	}

	public void post() {
	}

	/**
	 * register in this method your listeners
	 */
	public void pre() {
	}

	public boolean isTerminated() {
		return terminated;
	}

	public void setTerminated(boolean b) {
		this.terminated = b;
	}

	public boolean isInitialized() {
		return initialized;
	}
}
